local hx__minggou = fk.CreateSkill{
    name = "hx__minggou",

    tags = {},
}

hx__minggou:addEffect("active",{
    prompt = "hx__minggou__prompt",
    can_use = function (self, player)
        return not player:isNude() and player:usedSkillTimes(hx__minggou.name) < 3
    end,
    card_num = 1,
    card_filter = function (self, player, to_select, selected)
        return #selected == 0
    end,
    target_num = 3,
    target_filter = function (self, player, to_select, selected, selected_cards)
        return #selected < 3
    end,
    on_use = function (self, room, effect)
        local player = effect.from
        room:throwCard(effect.cards,hx__minggou.name,player,player)
        local num = 1
        if table.find(effect.tos,function (p)
            return not p:isWounded()
        end) then
            num = 2
        end
        if num == 2 then
            for _, v in ipairs(effect.tos) do
                room:setPlayerMark(v,"@hx__minggou__prohibit-turn",1)
            end
        end
        for _, v in ipairs(effect.tos) do
            room:damage{
                to = v,
                damage = num,
                damageType = fk.FireDamage,
                from = player,
            }
        end
    end,
})

hx__minggou:addEffect("prohibit",{
    prohibit_use = function (self, player, card)
        if player:getMark("@hx__minggou__prohibit-turn") > 0 then
            return card.trueName == "peach" or card.trueName == "analeptic"
        end
    end,
})

return hx__minggou